package com.itheima.d3_homework.timu2;

public class Test {
    public static void main(String[] args) {
        Computer computer = new Computer();
        computer.start();

        computer.useUSB(new USB(){

            @Override
            public void open() {
                System.out.println("鼠标打开");
            }

            @Override
            public void close() {
                System.out.println("鼠标关闭");
            }
        });

        computer.useUSB(new USB() {
            @Override
            public void open() {
                System.out.println("键盘打开");
            }

            @Override
            public void close() {
                System.out.println("键盘关闭");
            }
        });
        computer.stop();
    }
}
